from sqlalchemy import Column, String, Text

from app.models.base import BaseModel


class SysApiConfig(BaseModel):
    """
    API配置表
    """
    __tablename__ = "sys_api_config"
    
    code = Column(String(50), nullable=False, index=True, unique=True, comment="唯一代码")
    api_url = Column(String(255), nullable=False, comment="API地址")
    api_user = Column(String(64), comment="API用户")
    api_pwd = Column(String(255), comment="API密码")
    api_key = Column(String(255), comment="API Key")
    token = Column(String(255), comment="令牌")
    remarks = Column(Text, comment="备注")